package com.aviation.sell_ticket.mapper;

import com.aviation.sell_ticket.pojo.Aviation_airport;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface AirportMapper {

    @Select("select airport_id,airport_name from aviation_airport where city_id=#{cityId}")
    public List<Aviation_airport> obtainAirport(@Param("cityId") Integer cityId);

    @Select("select airport_id,airport_name,city_id from aviation_airport where airport_id=#{airportId}")
    public List<Aviation_airport> middleAirportQuery(@Param("airportId") Integer airportId);

    @Select("select * from aviation_airport")
    public List<Aviation_airport> airportWhole();

}
